/*
  Copyright (c) 2010 Les Newell. All rights reserved

  This program is free software: you can redistribute it and/or modify
  it under the terms of the GNU General Public License as published by
  the Free Software Foundation, either version 3 of the License, or
  (at your option) any later version.

  This program is distributed in the hope that it will be useful,
  but WITHOUT ANY WARRANTY; without even the implied warranty of
  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  GNU General Public License for more details.

  You should have received a copy of the GNU General Public License
  along with this program. If not, see <http://www.gnu.org/licenses/>.
*/

#ifndef COMMON_H_INCLUDED
#define COMMON_H_INCLUDED

#ifdef ARDUINO
#include "arduino_headers.h"
#endif

//something needs to handle these. By default the Serial module does.
void Error(const char * src);
void Errorln(const char * src);
void Error(const int src);
void Errorln(const int src);
void Error(const float src);
void Errorln(const float src);

//This function must be defined somewhere.
//It should return the average CPU load in percent
int GetCPULoad();

enum COMMAND{PITCH,ROLL,YAW,THROTTLE,MAX_COMMANDS};
enum AXIS{AXISX,AXISY,AXISZ,MAX_AXES};

#endif //#define COMMON_H_INCLUDED


